<!DOCTYPE html>
<html>
<head>
 <meta charset="UTF-8">
 <title>css组合选择器-子元素选择器</title>
 <style type="text/css">
 div > span{
	background-color:#b4b4b4;
 }
 
  div > h1 >span{
	background-color:#b4b4b4;
 }
 div > span > p{
	background-color:#F00;
	width:100px;
 }
</style>
 </head>
 <body>
	<div>
		<h1>黑山<span>老妖</span></h1>
		<span>聂小倩
		<p>宁采臣</p>
		</span>
		
	</div>
 </body>
 </html>